package Builder.one;

/**
 * @ProjectName: 23种设计模式
 * @Package: Builder
 * @ClassName: Worker
 * @Author: renhan
 * @Description:
 * @Date: 2020/11/18 20:32
 * @Version: 1.0
 *
 * 
 */
public class Worker extends Builder {
    private Product product;
    public Worker() {
        product = new Product();
    }
    @Override
    void buildA() {
        product.setBuildA("地基");
        System.out.println("地基");
    }

    @Override
    void buildB() {
        product.setBuildB("钢筋");
        System.out.println("钢筋");
    }

    @Override
    void buildC() {
        product.setBuildC("水泥");
        System.out.println("水泥");
    }

    @Override
    void buildD() {
        product.setBuildD("铺电线");
        System.out.println("铺电线");
    }
    Product getProduct(){
        return product;
    }
}
